<script setup lang="ts">
const emits = defineEmits<{
  (e: "open", value: string): void;
  // 显示通知信息
  (e: "showNotice"): void;
}>();
</script>

<template>
  <div class="navs">
    <div class="d d0" @click="emits('showNotice')">
      我要投诉
      <img width="40" height="40" src="/src/assets/index/d0.webp" />
    </div>

    <div class="d d1">
      我要查询
      <img width="40" height="40" src="/src/assets/index/d1.webp" />
    </div>

    <div class="a">
      <img width="40" height="40" src="/src/assets/index/a0.webp" />
      政策法规
    </div>

    <div class="a">
      <img width="40" height="40" src="/src/assets/index/a1.webp" />
      典型案例
    </div>

    <div class="a" @click="emits('open', '/help')">
      <img width="40" height="40" src="/src/assets/index/a2.webp" />
      帮助中心
    </div>

    <div class="b">
      <img width="64" height="64" src="/src/assets/index/b0.webp" />
      微信公众号
    </div>

    <div class="b">
      <img width="64" height="64" src="/src/assets/index/b1.webp" />
      微信小程序
    </div>
  </div>
</template>

<style scoped lang="scss">
.navs {
  width: 100%;
  height: 100%;
  background: #ffffff;
  padding: 16px;

  display: grid;
  grid-template-columns: repeat(3, 1fr);
  grid-template-rows: 64px 64px 88px auto;
  gap: 10px;
  > div {
    width: 100%;
    height: 100%;
    cursor: pointer;
  }
}

.d {
  grid-column: 1 / -1;
  width: 100%;
  height: 100%;
  font-size: 24px;
  font-weight: bold;
  color: #ffffff;
  padding: 12px 24px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  border-radius: 10px;
}

.d0 {
  background: linear-gradient(90deg, #f25c4e 0%, #ffa06a 100%);
}

.d1 {
  background: linear-gradient(90deg, #5a7afa 0%, #3dc1ff 100%);
}

.a {
  flex-direction: column;
  @include flexCenterCenter;
  border-radius: 4px;
  background: #eff9ff;
  gap: 8px;

  font-size: 14px;
  color: #333333;
}

.b {
  flex-direction: column;
  @include flexCenterCenter;
  border-radius: 4px;
  gap: 8px;
  font-weight: 400;
  font-size: 14px;
  color: #000000;
}
</style>
